import Vue from 'vue'
import App from './App.vue'
import axios from 'axios';
Vue.prototype.$axios = axios;


import Vant from 'vant';
import { Lazyload } from 'vant';
Vue.use(Lazyload);
import less from 'less';
import 'vant/lib/index.css';
import router from './router'
import VueWechatTitle from 'vue-wechat-title'
Vue.use(VueWechatTitle)
Vue.config.productionTip = false
Vue.use(Vant);
Vue.use(less);
import 'element-ui/lib/theme-chalk/index.css';
import { Upload, Table, TableColumn, Divider, Form, FormItem, Input, Option, Select, DatePicker, Button } from 'element-ui'
Vue.use(Upload)
Vue.use(Button)
Vue.use(Table)
Vue.use(Form)
Vue.use(Option)
Vue.use(Input)
Vue.use(FormItem)
Vue.use(TableColumn)
Vue.use(Divider)
Vue.use(Select)
Vue.use(DatePicker)

// import AMapLoader from "@amap/amap-jsapi-loader";

// AMapLoader.load({
//   'key': '88756b5c865be729aa02adbc0a1691ce',
//   'version': '2.0',   // 指定要加载的 JSAPI 的版本，缺少时默认为 1.4.15
//   'plugins': ['AMap.Scale', 'AMap.GeoJSON']           // 需要使用的的插件列表，如比例尺'AMap.Scale'等，更多插件请看官方文档
// }).then((AMap) => {
//   Vue.use(AMap)
// })

router.afterEach((to, from, next) => {
  window.scrollTo(0, 0)

})
new Vue({
  render: h => h(App),
  router,
}).$mount('#app')
